package elsim.common

import org.junit.Test;

class ClockTest {
  @Test
  void testClockBasic() {
    int clockValue = Clock.clock.getClockValue()
    Clock.clock.tick()
    assert (clockValue + 1 == Clock.clock.getClockValue())

    Clock.clock.registerObject(new Tickable() {
          void tick(int clock) {
            assert (clock == 2)
          }
        })

    Clock.clock.tick()

    Tickable otherObject = new Tickable() {
          void tick(int clock) {

            assert(clock == 2)
          }
        }
  }
}
